IMFExPart Struct Reference
[MCFrame]

Inheritance diagram for IMFExPart:

IMCUnknown TBasicPart TBasicDropCandidate List of all members.

Public Member Functions

virtual void MCCOMAPI ValidateCaches ()=0
virtual void MCCOMAPI SelfActivate (boolean beActive)=0
virtual void MCCOMAPI SetShown (boolean inShown)=0
virtual void MCCOMAPI BaseWindowBecameVisible (boolean inShown)=0
virtual boolean MCCOMAPI SelfMouseMoved (const TMCPoint &inWhere, const TMCModifiers &inModifiers)=0
virtual void MCCOMAPI SelfMouseEntering (const TMCPoint &inWhere, const TMCModifiers &inModifiers)=0
virtual void MCCOMAPI SelfMouseStillInside (const TMCPoint &inWhere, const TMCModifiers &inModifiers)=0
virtual void MCCOMAPI SelfMouseLeaving (const TMCModifiers &inModifiers)=0
virtual void MCCOMAPI SelfTrackDragAndDropEntering (const TMCPoint &inWhere, const TMFDragFlavors &inOfferedTypeList)=0
virtual void MCCOMAPI SelfTrackDragAndDropStillInside (const TMCPoint &inWhere, const TMFDragFlavors &inOfferedTypeList)=0
virtual void MCCOMAPI SelfTrackDragAndDropLeaving (const TMFDragFlavors &inOfferedTypeList)=0
virtual TMFEventResult MCCOMAPI SelfMouseDown (const TMCPoint &inWhere, const TMCPlatformEvent &inEvent)=0
virtual boolean MCCOMAPI SelfContextMouseDown (const TMCPoint &inWhere, const TMCPlatformEvent &inEvent)=0
virtual boolean MCCOMAPI SelfMiddleMouseDown (const TMCPoint &inWhere, const TMCPlatformEvent &inEvent)=0
virtual void MCCOMAPI SelfDraw (IMCGraphicContext *inContext, const TMCRect &inUpdateBBox)=0
virtual void MCCOMAPI SelfPrepareToDestroy ()=0
virtual void MCCOMAPI FinishRead ()=0
virtual boolean MCCOMAPI ParentChangedBounds (const TMCRect &oldBounds, const TMCRect &newBounds, boolean inval)=0
virtual void MCCOMAPI GetDropArea (const TMCPoint &inWhere, IMFDropCandidate &inCandidate, IDType &outAcceptedFlavor, IMFDropArea **outDropArea, boolean &outDrawDropCandidate)=0
virtual boolean MCCOMAPI GetValue (void *outValue, MFPartValueType inValueType) const =0
virtual boolean MCCOMAPI SetValue (const void *inValue, MFPartValueType inValueType, boolean inImmediateUpdate, boolean inNotify)=0
virtual boolean MCCOMAPI ChangedBounds (const TMCRect &oldBounds, const TMCRect &newBounds, boolean inval)=0
virtual TComponentClass *MCCOMAPI GetCursorID (const TMCPoint &inWhere, MFCursorID &outCursorID) const =0
virtual boolean MCCOMAPI SelfMouseWheel (const TMCPoint &inWhere, const TMCModifiers &inModifiers, int16 inWheelDelta)=0
virtual boolean MCCOMAPI ReadAttribute (int32 inKeyword, TMCiostream &inStream)=0
virtual void MCCOMAPI FinishCreateFromResource ()=0
virtual TMCPlatformWindow
*MCCOMAPI 
GetPlatformWindow ()=0

Detailed Description

This is the interface for an external part. To implement your own part you should derive your object from TBasicPart which provides a basic implementation of the methods of IMFExPart.

Note that you only need to implement a few methods to get a valid part (SelfDraw is sometimes enough).

The family ID for a part extension is 'part'. For more information on custom parts, see the Overview of the SDK.


Member Function Documentation

virtual void MCCOMAPI IMFExPart::BaseWindowBecameVisible (  boolean  inShown  )  [pure virtual]
 

When the window that contains the part just became visible/invisible.

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::ChangedBounds (  const TMCRect &  oldBounds,
const TMCRect &  newBounds,
boolean  inval
)  [pure virtual]
 

Notifies the EXPart that its bounds have changed. It is notification only. the internal has already adjusted

Parameters:
oldBounds Old bounds of the part
newBounds New bounds of the part
inval True if the part should be invalidated.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::FinishCreateFromResource (   )  [pure virtual]
 

Override if you need to perform some initialisations that you couldn't do in FinishRead (eg because you need the part's parent).

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::FinishRead (   )  [pure virtual]
 

Called just after reading the part from the resource.

Implemented in TBasicPart.

virtual TComponentClass* MCCOMAPI IMFExPart::GetCursorID (  const TMCPoint &  inWhere,
MFCursorID &  outCursorID
)  const [pure virtual]
 

Returns the Identifier of the cursor that should be used when the mouse pointer is over the part.

Parameters:
inWhere The position of the mouse cursor.
outCursorID the Identifier of the cursor
Returns:
a pointer to the component class the app needs to use in order to load the cursor's resource (very rarely needed). Returning null will use this (IMFExPart) resources.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::GetDropArea (  const TMCPoint &  inWhere,
IMFDropCandidate &  inCandidate,
IDType &  outAcceptedFlavor,
IMFDropArea **  outDropArea,
boolean &  outDrawDropCandidate
)  [pure virtual]
 

Returns a pointer to a drop area for this part. Called when the users drops an object on the part.

Parameters:
inWhere The position of the mouse
inCandidate The object that is dropped
outAcceptedFlavor Returns the type that is accepted if any.
outDropArea Returns a drop area if there is one, NULL otherwise.
outDrawDropCandidate Draw the drop candidate or not.

Implemented in TBasicPart.

virtual TMCPlatformWindow* MCCOMAPI IMFExPart::GetPlatformWindow (   )  [pure virtual]
 

Returns the plaform window attached to the part if any. Usually you do not need to implement this method. Return NULL if no platform windows is attached to this part in which the platform window of the parent window should be used

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::GetValue (  void *  outValue,
MFPartValueType  inValueType
)  const [pure virtual]
 

Returns the value of the part.

Returns:
true if outValue is valid (i.e., the external part handled the GetValue) and false otherwise
Parameters:
outValue A pointer to a buffer when the value should be stored.
inValueType The type of value requested.

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::ParentChangedBounds (  const TMCRect &  oldBounds,
const TMCRect &  newBounds,
boolean  inval
)  [pure virtual]
 

Called each time the bounds of the parent's part were changed.

Parameters:
oldBounds The old bounds of the parent.
newBounds The new bounds of the parent.
inval True if the part should be invalidated.

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::ReadAttribute (  int32  inKeyword,
TMCiostream &  inStream
)  [pure virtual]
 

Reads an attribute of the part from a stream (file usually).

Parameters:
inKeyword The keyword identifying the attribute.
inStream The stream.
Returns:
true if the attribute has been read.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfActivate (  boolean  beActive  )  [pure virtual]
 

Called when the part is activated/deactivated.

Parameters:
beActive True if the part is activated. False if it is deactivated.

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::SelfContextMouseDown (  const TMCPoint &  inWhere,
const TMCPlatformEvent &  inEvent
)  [pure virtual]
 

Handles a click with the right button of the mouse within the part's bounds

Parameters:
inWhere point in local coordinates of the mouse down
inEvent event information (like clickcount)

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfDraw (  IMCGraphicContext *  inContext,
const TMCRect &  inUpdateBBox
)  [pure virtual]
 

Called to ask the part to draw itself.

Parameters:
inContext The graphic context to use for the drawing.
inUpdateBBox The rectangle that should be drawn.

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::SelfMiddleMouseDown (  const TMCPoint &  inWhere,
const TMCPlatformEvent &  inEvent
)  [pure virtual]
 

Handles a click with the middle button of the mouse within the part's bounds

Parameters:
inWhere point in local coordinates of the mouse down
inEvent event information (like clickcount)

Implemented in TBasicPart.

virtual TMFEventResult MCCOMAPI IMFExPart::SelfMouseDown (  const TMCPoint &  inWhere,
const TMCPlatformEvent &  inEvent
)  [pure virtual]
 

Handles a click with the left button of the mouse within the part's bounds

Note: When the previous implementation returned a boolean result, you should now return TMFEventResult(result, result) in most cases.

Parameters:
inWhere point in local coordinates of the mouse down
inEvent event information (like clickcount)

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfMouseEntering (  const TMCPoint &  inWhere,
const TMCModifiers &  inModifiers
)  [pure virtual]
 

Called when the mouse cursor enters the part.

Parameters:
inWhere The position of the mouse.
inModifiers The modifier keys (Shift, Ctrl...)

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfMouseLeaving (  const TMCModifiers &  inModifiers  )  [pure virtual]
 

Called when the mouse has just left the part.

Parameters:
inModifiers The modifier keys (Shift, Ctrl...)

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::SelfMouseMoved (  const TMCPoint &  inWhere,
const TMCModifiers &  inModifiers
)  [pure virtual]
 

Called when the mouse has moved over the part.

Parameters:
inWhere The position of the mouse.
inModifiers The modifier keys (Shift, Ctrl...)

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfMouseStillInside (  const TMCPoint &  inWhere,
const TMCModifiers &  inModifiers
)  [pure virtual]
 

Called when the mouse cursor moves inside the part.

Parameters:
inWhere The position of the mouse.
inModifiers The modifier keys (Shift, Ctrl...)

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::SelfMouseWheel (  const TMCPoint &  inWhere,
const TMCModifiers &  inModifiers,
int16  inWheelDelta
)  [pure virtual]
 

Overide this if you want to handle the mouse wheel. Return true if you handled it

Parameters:
inWhere The position of the mouse cursor.
inModifiers The state of the modifier keys (Shift, Ctrl,...)
inWheelDelta The delta of the mouse wheel.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfPrepareToDestroy (   )  [pure virtual]
 

Called when the part is about to be destroyed to give it an opportunity to release all counted references and caches.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfTrackDragAndDropEntering (  const TMCPoint &  inWhere,
const TMFDragFlavors &  inOfferedTypeList
)  [pure virtual]
 

Function called when the mouse enters the Part during a drag and drop.

Parameters:
inWhere Point in local coordinate space where the cursor is
inOfferedTypeList Flavors offered by the current drop candiadate.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfTrackDragAndDropLeaving (  const TMFDragFlavors &  inOfferedTypeList  )  [pure virtual]
 

Function called when the mouse leaves the Part during a drag and drop.

Parameters:
inOfferedTypeList Flavors offered by the current drop candiadate.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SelfTrackDragAndDropStillInside (  const TMCPoint &  inWhere,
const TMFDragFlavors &  inOfferedTypeList
)  [pure virtual]
 

Function called when the mouse track within the Part during a drag and drop.

Parameters:
inWhere Point in local coordinate space where the cursor is
inOfferedTypeList Flavors offered by the current drop candiadate.

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::SetShown (  boolean  inShown  )  [pure virtual]
 

Sets the visibility of the part.

Parameters:
inShown 

Implemented in TBasicPart.

virtual boolean MCCOMAPI IMFExPart::SetValue (  const void *  inValue,
MFPartValueType  inValueType,
boolean  inImmediateUpdate,
boolean  inNotify
)  [pure virtual]
 

Sets the value of the part.

Parameters:
inValue A pointer to the value
inValueType The type of the value
inImmediateUpdate 
inNotify 
Returns:
true if outValue is valid (i.e., the external part handled the GetValue) and false otherwise

Implemented in TBasicPart.

virtual void MCCOMAPI IMFExPart::ValidateCaches (   )  [pure virtual]
 

Tells us that we can validate our caches because we're going to need them in the next draw

Implemented in TBasicPart.


The documentation for this struct was generated from the following file:
Generated on Wed Dec 7 14:27:37 2005 for Carrara SDK Doc by  doxygen 1.4.5